package com.antoni.pojo;

import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * @Author Zhang Chao
 * @Date 2021/5/15 13:50
 * @Version 1.0
 */

public class Book implements Serializable {
    @NotEmpty(message = "密码不能为空")
    @Length(min = 6,max = 8,message = "密码长度为6-8")
    @Pattern(regexp = "[a-zA-z]",message = "密码不合法")
    private String password;
}
